import request from '@/router/axios';

/**
 * 获取全部游戏列表
 * @returns {AxiosPromise}
 */
export const getGameAll = () => {
  return request({
    url: '/api/blade-game/game/all',
    method: 'get'
  })
}
export const gameTypeList = (gameType) => {
  return request({
    url: '/api/blade-game/gametype/gameTypeList',
    method: 'get',
    params: {
      ...gameType
    }
  })
}
export const gameList = (gameProject) => {
  return request({
    url: '/api/blade-game/gameproject/gameList',
    method: 'get',
    params: {
      ...gameProject
    }
  })
}

export const gameVOList = (gameProject) => {
  return request({
    url: '/api/blade-game/gameproject/gameVOList',
    method: 'get',
    params: {
      ...gameProject
    }
  })
}
export const gameserverList = (GameServerDTO) => {
  return request({
    url: '/api/blade-game/gameserver/gameserverList',
    method: 'get',
    params: {
      ...GameServerDTO

    }
  })
}
export const gamePhoneList = (game) => {
  return request({
    url: '/api/blade-game/game/gameList',
    method: 'get',
    params: {
      ...game
    }
  })
}
export const gameDetail = (game) => {
  return request({
    url: '/api/blade-game/game/detail',
    method: 'get',
    params: {
      ...game
    }
  })
}

export const gameLinksettings = () => {
  return request({
    url: '/api/blade-game/linksettings/detail',
    method: 'get'
  })
}

export const save = (linksettings) => {
  return request({
    url: '/api/blade-game/linksettings/save',
    method: 'post',
    data:linksettings
  })
}

export const gamePromote = (linksettings) => {
  return request({
    url: '/api/blade-game/linksettings/gamePromote',
    method: 'post',
    data:linksettings
  })
}

